FROM 43.138.217.116:8077/k8sphp/base

WORKDIR /app

COPY ./composer.json /app/
COPY ./composer.lock /app/

ENV COMPOSER_ALLOW_SUPERUSER=1
RUN set -eux
#RUN composer update
RUN composer install --ignore-platform-req=ext-gd --no-autoloader --no-scripts
#ignore-platform-req 忽略版本冲突

COPY . /app

CMD php artisan serve --host=0.0.0.0 --port=8000

EXPOSE 8000

RUN chmod 777 ./entrypoint.sh

ENTRYPOINT ["./entrypoint.sh"]


#docker buildx build -t 43.138.217.116:8077/k8sphp/phpcronduo:latest  -f Test.Dockerfile --platform=linux/amd64 .
#docker login -u admin -p Harbor12345 43.138.217.116:8077
